// 这边封装一系列token的本地操作
// localStorage sessionStorage cookie(4k)   token字符串
// 会用cookie演示本地操作
import Cookies from 'js-cookie'
// localStorage.getItem('xxx')            Cookies.get('xxx')
// localStorage.setItem('xxx', 'fff')     Cookies.set('xxx', 'fff')
// localStorage.removeItem('xxx')         Cookies.remove('xxx')

const TokenKey = 'hm-106-hrsaas-token-key'

export function getToken() {
  return Cookies.get(TokenKey)
}

export function setToken(token) {
  return Cookies.set(TokenKey, token)
}

export function removeToken() {
  return Cookies.remove(TokenKey)
}
